3.237 \(\int \frac {\tan ^5(e+f x)}{(a+b \tan ^2(e+f x))^3} \, dx\)

Optimal. Leaf size=108 \[ \frac {a^2}{4 b^2 f (a-b) \left (a+b \tan ^2(e+f x)\right )^2}-\frac {a (a-2 b)}{2 b^2 f (a-b)^2 \left (a+b \tan ^2(e+f x)\right )}-\frac {\log \left (a \cos ^2(e+f x)+b \sin ^2(e+f x)\right )}{2 f (a-b)^3} \]

[Out]

-1/2*ln(a*cos(f*x+e)^2+b*sin(f*x+e)^2)/(a-b)^3/f+1/4*a^2/(a-b)/b^2/f/(a+b*tan(f*x+e)^2)^2-1/2*a*(a-2*b)/(a-b)^
2/b^2/f/(a+b*tan(f*x+e)^2)

________________________________________________________________________________________

Rubi [A]  time = 0.15, antiderivative size = 108, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 23, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.130, Rules used = {3670, 446, 88} \[ \frac {a^2}{4 b^2 f (a-b) \left (a+b \tan ^2(e+f x)\right )^2}-\frac {a (a-2 b)}{2 b^2 f (a-b)^2 \left (a+b \tan ^2(e+f x)\right )}-\frac {\log \left (a \cos ^2(e+f x)+b \sin ^2(e+f x)\right )}{2 f (a-b)^3} \]

Antiderivative was successfully verified.

[In]

Int[Tan[e + f*x]^5/(a + b*Tan[e + f*x]^2)^3,x]

[Out]

-Log[a*Cos[e + f*x]^2 + b*Sin[e + f*x]^2]/(2*(a - b)^3*f) + a^2/(4*(a - b)*b^2*f*(a + b*Tan[e + f*x]^2)^2) - (
a*(a - 2*b))/(2*(a - b)^2*b^2*f*(a + b*Tan[e + f*x]^2))

Rule 88

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Int[ExpandI
ntegrand[(a + b*x)^m*(c + d*x)^n*(e + f*x)^p, x], x] /; FreeQ[{a, b, c, d, e, f, p}, x] && IntegersQ[m, n] &&
(IntegerQ[p] || (GtQ[m, 0] && GeQ[n, -1]))

Rule 446

Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_))^(q_.), x_Symbol] :> Dist[1/n, Subst[Int
[x^(Simplify[(m + 1)/n] - 1)*(a + b*x)^p*(c + d*x)^q, x], x, x^n], x] /; FreeQ[{a, b, c, d, m, n, p, q}, x] &&
 NeQ[b*c - a*d, 0] && IntegerQ[Simplify[(m + 1)/n]]

Rule 3670

Int[((d_.)*tan[(e_.) + (f_.)*(x_)])^(m_.)*((a_) + (b_.)*((c_.)*tan[(e_.) + (f_.)*(x_)])^(n_))^(p_.), x_Symbol]
 :> With[{ff = FreeFactors[Tan[e + f*x], x]}, Dist[(c*ff)/f, Subst[Int[(((d*ff*x)/c)^m*(a + b*(ff*x)^n)^p)/(c^
2 + ff^2*x^2), x], x, (c*Tan[e + f*x])/ff], x]] /; FreeQ[{a, b, c, d, e, f, m, n, p}, x] && (IGtQ[p, 0] || EqQ
[n, 2] || EqQ[n, 4] || (IntegerQ[p] && RationalQ[n]))

Rubi steps

\begin {align*} \int \frac {\tan ^5(e+f x)}{\left (a+b \tan ^2(e+f x)\right )^3} \, dx &=\frac {\operatorname {Subst}\left (\int \frac {x^5}{\left (1+x^2\right ) \left (a+b x^2\right )^3} \, dx,x,\tan (e+f x)\right )}{f}\\ &=\frac {\operatorname {Subst}\left (\int \frac {x^2}{(1+x) (a+b x)^3} \, dx,x,\tan ^2(e+f x)\right )}{2 f}\\ &=\frac {\operatorname {Subst}\left (\int \left (\frac {1}{(a-b)^3 (1+x)}-\frac {a^2}{(a-b) b (a+b x)^3}+\frac {a (a-2 b)}{(a-b)^2 b (a+b x)^2}+\frac {b}{(-a+b)^3 (a+b x)}\right ) \, dx,x,\tan ^2(e+f x)\right )}{2 f}\\ &=-\frac {\log \left (a \cos ^2(e+f x)+b \sin ^2(e+f x)\right )}{2 (a-b)^3 f}+\frac {a^2}{4 (a-b) b^2 f \left (a+b \tan ^2(e+f x)\right )^2}-\frac {a (a-2 b)}{2 (a-b)^2 b^2 f \left (a+b \tan ^2(e+f x)\right )}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 1.16, size = 97, normalized size = 0.90 \[ \frac {\frac {a^2 (a-b)^2}{b^2 \left (a+b \tan ^2(e+f x)\right )^2}-\frac {2 a (a-2 b) (a-b)}{b^2 \left (a+b \tan ^2(e+f x)\right )}-2 \log \left (a+b \tan ^2(e+f x)\right )-4 \log (\cos (e+f x))}{4 f (a-b)^3} \]

Antiderivative was successfully verified.

[In]

Integrate[Tan[e + f*x]^5/(a + b*Tan[e + f*x]^2)^3,x]

[Out]

(-4*Log[Cos[e + f*x]] - 2*Log[a + b*Tan[e + f*x]^2] + (a^2*(a - b)^2)/(b^2*(a + b*Tan[e + f*x]^2)^2) - (2*a*(a
 - 2*b)*(a - b))/(b^2*(a + b*Tan[e + f*x]^2)))/(4*(a - b)^3*f)

________________________________________________________________________________________

fricas [B]  time = 0.45, size = 206, normalized size = 1.91 \[ \frac {{\left (a^{2} - 4 \, a b\right )} \tan \left (f x + e\right )^{4} - 2 \, {\left (a^{2} + 2 \, a b\right )} \tan \left (f x + e\right )^{2} - 3 \, a^{2} - 2 \, {\left (b^{2} \tan \left (f x + e\right )^{4} + 2 \, a b \tan \left (f x + e\right )^{2} + a^{2}\right )} \log \left (\frac {b \tan \left (f x + e\right )^{2} + a}{\tan \left (f x + e\right )^{2} + 1}\right )}{4 \, {\left ({\left (a^{3} b^{2} - 3 \, a^{2} b^{3} + 3 \, a b^{4} - b^{5}\right )} f \tan \left (f x + e\right )^{4} + 2 \, {\left (a^{4} b - 3 \, a^{3} b^{2} + 3 \, a^{2} b^{3} - a b^{4}\right )} f \tan \left (f x + e\right )^{2} + {\left (a^{5} - 3 \, a^{4} b + 3 \, a^{3} b^{2} - a^{2} b^{3}\right )} f\right )}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(f*x+e)^5/(a+b*tan(f*x+e)^2)^3,x, algorithm="fricas")

[Out]

1/4*((a^2 - 4*a*b)*tan(f*x + e)^4 - 2*(a^2 + 2*a*b)*tan(f*x + e)^2 - 3*a^2 - 2*(b^2*tan(f*x + e)^4 + 2*a*b*tan
(f*x + e)^2 + a^2)*log((b*tan(f*x + e)^2 + a)/(tan(f*x + e)^2 + 1)))/((a^3*b^2 - 3*a^2*b^3 + 3*a*b^4 - b^5)*f*
tan(f*x + e)^4 + 2*(a^4*b - 3*a^3*b^2 + 3*a^2*b^3 - a*b^4)*f*tan(f*x + e)^2 + (a^5 - 3*a^4*b + 3*a^3*b^2 - a^2
*b^3)*f)

________________________________________________________________________________________

giac [F(-2)]  time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: NotImplementedError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(f*x+e)^5/(a+b*tan(f*x+e)^2)^3,x, algorithm="giac")

[Out]

Exception raised: NotImplementedError >> Unable to parse Giac output: Unable to check sign: (2*pi/x/2)>(-2*pi/
x/2)2/f*(1/(2*a^3-6*a^2*b+6*a*b^2-2*b^3)*ln(abs((1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1)))+1))-1/(4*a^3-12*a^2*b+
12*a*b^2-4*b^3)*ln(((1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1))))^2*a-2*(1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1)))*a+4
*(1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1)))*b+a)+(3*((1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1))))^4*a^2-20*((1-cos(f*
x+exp(1)))/(1+cos(f*x+exp(1))))^3*a^2+32*((1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1))))^3*a*b+50*((1-cos(f*x+exp(1)
))/(1+cos(f*x+exp(1))))^2*a^2-128*((1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1))))^2*a*b+96*((1-cos(f*x+exp(1)))/(1+c
os(f*x+exp(1))))^2*b^2-20*(1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1)))*a^2+32*(1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1)
))*a*b+3*a^2)/(8*a^3-24*a^2*b+24*a*b^2-8*b^3)/(((1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1))))^2*a-2*(1-cos(f*x+exp(
1)))/(1+cos(f*x+exp(1)))*a+4*(1-cos(f*x+exp(1)))/(1+cos(f*x+exp(1)))*b+a)^2)

________________________________________________________________________________________

maple [B]  time = 0.20, size = 234, normalized size = 2.17 \[ -\frac {\ln \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )}{2 f \left (a -b \right )^{3}}-\frac {a^{3}}{2 f \left (a -b \right )^{3} b^{2} \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )}+\frac {3 a^{2}}{2 f \left (a -b \right )^{3} b \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )}-\frac {a}{f \left (a -b \right )^{3} \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )}+\frac {a^{4}}{4 f \left (a -b \right )^{3} b^{2} \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )^{2}}-\frac {a^{3}}{2 f \left (a -b \right )^{3} b \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )^{2}}+\frac {a^{2}}{4 f \left (a -b \right )^{3} \left (a +b \left (\tan ^{2}\left (f x +e \right )\right )\right )^{2}}+\frac {\ln \left (1+\tan ^{2}\left (f x +e \right )\right )}{2 f \left (a -b \right )^{3}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(f*x+e)^5/(a+b*tan(f*x+e)^2)^3,x)

[Out]

-1/2/f/(a-b)^3*ln(a+b*tan(f*x+e)^2)-1/2/f/(a-b)^3*a^3/b^2/(a+b*tan(f*x+e)^2)+3/2/f/(a-b)^3*a^2/b/(a+b*tan(f*x+
e)^2)-1/f/(a-b)^3*a/(a+b*tan(f*x+e)^2)+1/4/f/(a-b)^3*a^4/b^2/(a+b*tan(f*x+e)^2)^2-1/2/f/(a-b)^3*a^3/b/(a+b*tan
(f*x+e)^2)^2+1/4/f/(a-b)^3*a^2/(a+b*tan(f*x+e)^2)^2+1/2/f/(a-b)^3*ln(1+tan(f*x+e)^2)

________________________________________________________________________________________

maxima [A]  time = 0.54, size = 189, normalized size = 1.75 \[ \frac {\frac {4 \, {\left (a^{2} - a b\right )} \sin \left (f x + e\right )^{2} - 3 \, a^{2}}{a^{5} - 3 \, a^{4} b + 3 \, a^{3} b^{2} - a^{2} b^{3} + {\left (a^{5} - 5 \, a^{4} b + 10 \, a^{3} b^{2} - 10 \, a^{2} b^{3} + 5 \, a b^{4} - b^{5}\right )} \sin \left (f x + e\right )^{4} - 2 \, {\left (a^{5} - 4 \, a^{4} b + 6 \, a^{3} b^{2} - 4 \, a^{2} b^{3} + a b^{4}\right )} \sin \left (f x + e\right )^{2}} - \frac {2 \, \log \left (-{\left (a - b\right )} \sin \left (f x + e\right )^{2} + a\right )}{a^{3} - 3 \, a^{2} b + 3 \, a b^{2} - b^{3}}}{4 \, f} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(f*x+e)^5/(a+b*tan(f*x+e)^2)^3,x, algorithm="maxima")

[Out]

1/4*((4*(a^2 - a*b)*sin(f*x + e)^2 - 3*a^2)/(a^5 - 3*a^4*b + 3*a^3*b^2 - a^2*b^3 + (a^5 - 5*a^4*b + 10*a^3*b^2
 - 10*a^2*b^3 + 5*a*b^4 - b^5)*sin(f*x + e)^4 - 2*(a^5 - 4*a^4*b + 6*a^3*b^2 - 4*a^2*b^3 + a*b^4)*sin(f*x + e)
^2) - 2*log(-(a - b)*sin(f*x + e)^2 + a)/(a^3 - 3*a^2*b + 3*a*b^2 - b^3))/f

________________________________________________________________________________________

mupad [B]  time = 12.52, size = 577, normalized size = 5.34 \[ -\frac {a^3\,b\,{\cos \left (e+f\,x\right )}^4-\frac {a^4\,{\cos \left (e+f\,x\right )}^4}{4}-\frac {3\,a^2\,b^2\,{\cos \left (e+f\,x\right )}^4}{4}+b^4\,{\sin \left (e+f\,x\right )}^4\,\mathrm {atan}\left (\frac {a\,{\sin \left (e+f\,x\right )}^2-b\,{\sin \left (e+f\,x\right )}^2}{a\,{\cos \left (e+f\,x\right )}^2\,2{}\mathrm {i}+a\,{\sin \left (e+f\,x\right )}^2\,1{}\mathrm {i}+b\,{\sin \left (e+f\,x\right )}^2\,1{}\mathrm {i}}\right )\,1{}\mathrm {i}-a\,b^3\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2-\frac {a^3\,b\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2}{2}+a^2\,b^2\,{\cos \left (e+f\,x\right )}^4\,\mathrm {atan}\left (\frac {a\,{\sin \left (e+f\,x\right )}^2-b\,{\sin \left (e+f\,x\right )}^2}{a\,{\cos \left (e+f\,x\right )}^2\,2{}\mathrm {i}+a\,{\sin \left (e+f\,x\right )}^2\,1{}\mathrm {i}+b\,{\sin \left (e+f\,x\right )}^2\,1{}\mathrm {i}}\right )\,1{}\mathrm {i}+\frac {3\,a^2\,b^2\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2}{2}+a\,b^3\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2\,\mathrm {atan}\left (\frac {a\,{\sin \left (e+f\,x\right )}^2-b\,{\sin \left (e+f\,x\right )}^2}{a\,{\cos \left (e+f\,x\right )}^2\,2{}\mathrm {i}+a\,{\sin \left (e+f\,x\right )}^2\,1{}\mathrm {i}+b\,{\sin \left (e+f\,x\right )}^2\,1{}\mathrm {i}}\right )\,2{}\mathrm {i}}{f\,\left (-a^5\,b^2\,{\cos \left (e+f\,x\right )}^4+3\,a^4\,b^3\,{\cos \left (e+f\,x\right )}^4-2\,a^4\,b^3\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2-3\,a^3\,b^4\,{\cos \left (e+f\,x\right )}^4+6\,a^3\,b^4\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2-a^3\,b^4\,{\sin \left (e+f\,x\right )}^4+a^2\,b^5\,{\cos \left (e+f\,x\right )}^4-6\,a^2\,b^5\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2+3\,a^2\,b^5\,{\sin \left (e+f\,x\right )}^4+2\,a\,b^6\,{\cos \left (e+f\,x\right )}^2\,{\sin \left (e+f\,x\right )}^2-3\,a\,b^6\,{\sin \left (e+f\,x\right )}^4+b^7\,{\sin \left (e+f\,x\right )}^4\right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(tan(e + f*x)^5/(a + b*tan(e + f*x)^2)^3,x)

[Out]

-(a^3*b*cos(e + f*x)^4 - (a^4*cos(e + f*x)^4)/4 - (3*a^2*b^2*cos(e + f*x)^4)/4 + b^4*sin(e + f*x)^4*atan((a*si
n(e + f*x)^2 - b*sin(e + f*x)^2)/(a*cos(e + f*x)^2*2i + a*sin(e + f*x)^2*1i + b*sin(e + f*x)^2*1i))*1i - a*b^3
*cos(e + f*x)^2*sin(e + f*x)^2 - (a^3*b*cos(e + f*x)^2*sin(e + f*x)^2)/2 + a^2*b^2*cos(e + f*x)^4*atan((a*sin(
e + f*x)^2 - b*sin(e + f*x)^2)/(a*cos(e + f*x)^2*2i + a*sin(e + f*x)^2*1i + b*sin(e + f*x)^2*1i))*1i + (3*a^2*
b^2*cos(e + f*x)^2*sin(e + f*x)^2)/2 + a*b^3*cos(e + f*x)^2*sin(e + f*x)^2*atan((a*sin(e + f*x)^2 - b*sin(e +
f*x)^2)/(a*cos(e + f*x)^2*2i + a*sin(e + f*x)^2*1i + b*sin(e + f*x)^2*1i))*2i)/(f*(b^7*sin(e + f*x)^4 - 3*a*b^
6*sin(e + f*x)^4 + a^2*b^5*cos(e + f*x)^4 - 3*a^3*b^4*cos(e + f*x)^4 + 3*a^4*b^3*cos(e + f*x)^4 - a^5*b^2*cos(
e + f*x)^4 + 3*a^2*b^5*sin(e + f*x)^4 - a^3*b^4*sin(e + f*x)^4 + 2*a*b^6*cos(e + f*x)^2*sin(e + f*x)^2 - 6*a^2
*b^5*cos(e + f*x)^2*sin(e + f*x)^2 + 6*a^3*b^4*cos(e + f*x)^2*sin(e + f*x)^2 - 2*a^4*b^3*cos(e + f*x)^2*sin(e
+ f*x)^2))

________________________________________________________________________________________

sympy [A]  time = 133.67, size = 3346, normalized size = 30.98 \[ \text {result too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(tan(f*x+e)**5/(a+b*tan(f*x+e)**2)**3,x)

[Out]

Piecewise((zoo*x/tan(e), Eq(a, 0) & Eq(b, 0) & Eq(f, 0)), (-3*tan(e + f*x)**4/(6*b**3*f*tan(e + f*x)**6 + 18*b
**3*f*tan(e + f*x)**4 + 18*b**3*f*tan(e + f*x)**2 + 6*b**3*f) - 3*tan(e + f*x)**2/(6*b**3*f*tan(e + f*x)**6 +
18*b**3*f*tan(e + f*x)**4 + 18*b**3*f*tan(e + f*x)**2 + 6*b**3*f) - 1/(6*b**3*f*tan(e + f*x)**6 + 18*b**3*f*ta
n(e + f*x)**4 + 18*b**3*f*tan(e + f*x)**2 + 6*b**3*f), Eq(a, b)), ((log(tan(e + f*x)**2 + 1)/(2*f) + tan(e + f
*x)**4/(4*f) - tan(e + f*x)**2/(2*f))/a**3, Eq(b, 0)), (x*tan(e)**5/(a + b*tan(e)**2)**3, Eq(f, 0)), (-a**4/(4
*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f
*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b
**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) - 2*a**3*b*tan(e
+ f*x)**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24
*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**
2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) + 4*a
**3*b/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**
3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 -
4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) - 2*a**2*
b**2*log(-I*sqrt(a)*sqrt(1/b) + tan(e + f*x))/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f
+ 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x
)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)*
*2 - 4*b**7*f*tan(e + f*x)**4) - 2*a**2*b**2*log(I*sqrt(a)*sqrt(1/b) + tan(e + f*x))/(4*a**5*b**2*f + 8*a**4*b
**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a
**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan
(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) + 2*a**2*b**2*log(tan(e + f*x)**2 + 1)/(
4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*
f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*
b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) + 6*a**2*b**2*ta
n(e + f*x)**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4
- 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*
x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) -
 3*a**2*b**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 -
 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x
)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) -
4*a*b**3*log(-I*sqrt(a)*sqrt(1/b) + tan(e + f*x))*tan(e + f*x)**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)*
*2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**
2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*
b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) - 4*a*b**3*log(I*sqrt(a)*sqrt(1/b) + tan(e + f*x))*tan(e +
f*x)**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a
**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2
- 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) + 4*a*b
**3*log(tan(e + f*x)**2 + 1)*tan(e + f*x)**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f +
 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)
**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**
2 - 4*b**7*f*tan(e + f*x)**4) - 4*a*b**3*tan(e + f*x)**2/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a
**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*
tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*ta
n(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) - 2*b**4*log(-I*sqrt(a)*sqrt(1/b) + tan(e + f*x))*tan(e + f*x)**4/(4
*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f
*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b
**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4) - 2*b**4*log(I*sq
rt(a)*sqrt(1/b) + tan(e + f*x))*tan(e + f*x)**4/(4*a**5*b**2*f + 8*a**4*b**3*f*tan(e + f*x)**2 - 12*a**4*b**3*
f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**3*b**4*f - 12*a**2*b**5*f*tan(e + f
*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e + f*x)**4 - 8*a*b**6*f*tan(e + f*x
)**2 - 4*b**7*f*tan(e + f*x)**4) + 2*b**4*log(tan(e + f*x)**2 + 1)*tan(e + f*x)**4/(4*a**5*b**2*f + 8*a**4*b**
3*f*tan(e + f*x)**2 - 12*a**4*b**3*f + 4*a**3*b**4*f*tan(e + f*x)**4 - 24*a**3*b**4*f*tan(e + f*x)**2 + 12*a**
3*b**4*f - 12*a**2*b**5*f*tan(e + f*x)**4 + 24*a**2*b**5*f*tan(e + f*x)**2 - 4*a**2*b**5*f + 12*a*b**6*f*tan(e
 + f*x)**4 - 8*a*b**6*f*tan(e + f*x)**2 - 4*b**7*f*tan(e + f*x)**4), True))

________________________________________________________________________________________